// Factory.h 
 
#ifndef _ABSTRACTFACTORY_H_ 
#define _ABSTRACTFACTORY_H_ 
 
class AbstratcProductA;
class AbstratcProductB;
 
class AbstractFactory
{ 
public: 
	virtual ~AbstractFactory ()  = 0 ;  
 
	virtual  AbstratcProductA*  CreateProductA()  = 0; 
	virtual  AbstratcProductB*  CreateProductB()  = 0; 
 
protected: 
 	AbstractFactory(); 
 
private: 
 
}; 

class ConcreteFactory1:public AbstractFactory  
{ 
public: 
 
	~ConcreteFactory1 (); 
	 
	ConcreteFactory1(); 
	 
	AbstratcProductA*  CreateProductA(); 
	AbstratcProductB*  CreateProductB(); 
 
protected: 
 
private:
 
}; 
 
class ConcreteFactory2:public AbstractFactory  
{ 
public: 
 
	~ConcreteFactory2(); 
	 
	ConcreteFactory2(); 
	 
	AbstratcProductA*  CreateProductA(); 
	AbstratcProductB*  CreateProductB(); 
 
protected: 
 
private:
 
}; 

#endif //~_F ACTORY_H_